/*CREATE PROCEDURE dbo.spSireassCatCargo
@Accion AS SMALLINT,
@nId_Cargo AS BIGINT = null,
@cCargoGral AS VARCHAR(100) = null,
@cCargoFem AS VARCHAR(100) = null,
@cCargoMas AS VARCHAR(100) = null,
@bHabilitado AS BIT = null,
@dFecha_Alta AS DATETIME2 = null,
@dFecha_Baja AS DATETIME2 = null

USE AdventureWorks2012;
GO
EXEC dbo.uspGetEmployeeManagers @BusinessEntityID = 50;

EXEC AdventureWorks2012.dbo.uspGetEmployeeManagers 50;
GO
*/

EXEC sireass_db.dbo.spSireassCatCargo @Accion=1

declare @fecha as datetime
set @fecha = SYSDATETIME()
EXEC sireass_db.dbo.spSireassCatCargo 
	@Accion=2, 
	@cCargoGral = 'Jefe de Departamento',
	@cCargoFem  = 'Jefa de Departamento',
	@cCargoMas  = 'Jefe de Departamento',
	@bHabilitado = 1,
	@dFecha_Alta = @fecha;
	
EXEC sireass_db.dbo.spSireassCatCargo @Accion=1;

declare @fecha as datetime
set @fecha = SYSDATETIME()
EXEC sireass_db.dbo.spSireassCatCargo 
	@Accion=4,
	@nId_Cargo = 1, 
	@cCargoGral = 'Jefe de Departamento',
	@cCargoFem  = 'Jefa de Departamento',
	@cCargoMas  = 'Jefe de Departamento',
	@bHabilitado = 0,
	@dFecha_Alta = @fecha,
	@dFecha_Baja = @fecha;
	
EXEC sireass_db.dbo.spSireassCatCargo @Accion=1;

EXEC sireass_db.dbo.spSireassCatCargo 
	@Accion=3,
	@nId_Cargo = 1
	
EXEC sireass_db.dbo.spSireassCatCargo @Accion=1;

select * from sireass_db.dbo.Cat_Cargo;

GO

EXEC sireass_db.dbo.spSireassNombreValor @Tabla='Cat_Cargo' 

go